<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:ui="http://java.sun.com/jsf/facelets"> 
	<f:view>
		<h:head>
			<title>#{msgs.registrationTitle}</title>
			<link href="../../11/exercise/css/style.css" rel="stylesheet" type="text/css" />
		</h:head> 
		<body class="#{formSettings.bodyColorStyle}"> 
<h3>
			<h:outputFormat value="#{msgs.registrationText}">
					<f:param value="#{msgs.firstNamePrompt}" />
					<f:param value="#{msgs.lastNamePrompt}" />
					<f:param value="#{msgs.emailAddressPrompt}" />
				</h:outputFormat>
			</h3>
			
			<h:form>
				<fieldset>
					<legend>#{msgs.registrationTitle}</legend>
					<h:outputFormat value="#{msgs.prompt}" >
						<f:param value="#{msgs.firstNamePrompt}" />
					</h:outputFormat>
					<h:inputText value="#{person5.firstName}" />
					
					<br/>
					
					<h:outputFormat value="#{msgs.prompt}">
						<f:param value="#{msgs.lastNamePrompt}"/>
					</h:outputFormat>
					<h:inputText value="#{person5.lastName}" />
					
					<br/>
					
					<h:outputFormat value="#{msgs.prompt}" >
						<f:param value="#{msgs.emailAddressPrompt}"/>
					</h:outputFormat>
					<h:inputText value="#{person5.emailAddress}" />
					
					<br/>
					
					<h:commandButton action="#{person5.doRegistration()}" value="#{msgs.buttonLabel}" />
					
				</fieldset>
				
				<br/>
				
				<div align="center">
					
					
					<h:commandButton actionListener="#{formSettings.setBlackColor}" value="#{msgs.switchColor}" immediate="true" />
					&nbsp;&nbsp;#{msgs.switchColor}:
					<h:selectBooleanCheckbox 
						value="#{formSettings.checked}"
						valueChangeListener="#{formSettings.swapColor}"
						onclick="submit()" 
						immediate="true" />
				</div>
			</h:form>
		</body>
	</f:view> 
</html>
